// window 事件
export const EVENT_TRANSFER_QUERY = 'EVENT_TRANSFER_QUERY' // 查询表
export const EVENT_TRANSFER_UPDATED = 'EVENT_TRANSFER_UPDATED' // 表更新了
export const EVENT_TRANSFER_ADD = 'EVENT_TRANSFER_ADD' // 添加项
export const EVENT_TRANSFER_DELETE_DB = 'EVENT_TRANSFER_DELETE_DB' // 删库
export const EVENT_TRANSFER_UPDATE_ITEM = 'EVENT_TRANSFER_UPDATE_ITEM' // 更新表项

export class TransferItem {
  constructor(data = {}) {
    this.id = data.id // 新建时不需要传入，数据库自增id
    this.filename = data.filename
    this.url = data.url
    this.progress = data.progress
    this.directoryPath = data.directoryPath
  }
}
